//
//  StoreDataHeaderView.m
//  Manager
//
//  Created by Mr.Lee on 2018/4/18.
//  Copyright © 2018年 Reabam. All rights reserved.
//

#import "StoreDataHeaderView.h"

@implementation StoreDataHeaderView


+ (instancetype)storeDataHeaderViewWithNib{
    return [[[NSBundle mainBundle] loadNibNamed:NSStringFromClass(self) owner:nil options:nil] firstObject];
}
- (instancetype)initWithFrame:(CGRect)frame {
    
    self = [super initWithFrame:frame];
    
    if (self) {
        
        self = [[NSBundle mainBundle] loadNibNamed:@"StoreDataHeaderView" owner:self options:nil][0];
        self.frame = frame;// 必须给View的frame赋值
        
    }
    
    return self;
    
}

- (void)layoutSubviews {
    [super layoutSubviews];
    self.height = 100;
    self.width = ScreenWidth;
}
- (IBAction)switchBtnClick:(UIButton *)sender {
    
    if ([self.delegate respondsToSelector:@selector(switchBtnClick:)]) {
        [self.delegate switchBtnClick:sender];
    }
}


@end
